<?php
/**
 * State constant
 *
 */
class StateConstant {

    public static function getStateList(){
        $translate = Zend_Registry::get('Zend_Translate');
        $state = array(
                    'AZ' => $translate->_('az'),
                    'CA' => $translate->_('california'),
                    'NV' => $translate->_('nevada'),
                    'FL' => $translate->_('florida'),
                    'AL' => $translate->_('alabama'),
                    'AK' => $translate->_('alaska'),
                    'AR' => $translate->_('arkansas'),
                    'CO' => $translate->_('colorado'),
                    'CT' => $translate->_('connecticut'),
                    'DE' => $translate->_('delaware'),
                    'DC' => $translate->_('districtofcolumbia'),
                    'GA' => $translate->_('georgia'),
                    'HI' => $translate->_('Hawaii'),
                    'ID' => $translate->_('idaho'),
                    'IL' => $translate->_('illinois'),
                    'IN' => $translate->_('indiana'),
                    'KA' => $translate->_('kansas'),
                    'KY' => $translate->_('kentucky'),
                    'LA' => $translate->_('louisiana'),
                    'ME' => $translate->_('maine'),
                    'MD' => $translate->_('maryland'),
                    'MA' => $translate->_('massachusetts'),
                    'MI' => $translate->_('michigan'),
                    'MN' => $translate->_('minnesota'),
                    'MS' => $translate->_('mississippi'),
                    'MO' => $translate->_('missouri'),
                    'MT' => $translate->_('montana'),
                    'NE' => $translate->_('nebraska'),
                    'NH' => $translate->_('newhampshire'),
                    'NJ' => $translate->_('newjersey'),
                    'NY' => $translate->_('newyork'),
                    'NC' => $translate->_('northcarolina'),
                    'ND' => $translate->_('northdakota'),
                    'OH' => $translate->_('ohio'),
                    'OK' => $translate->_('oklahoma'),
                    'OR' => $translate->_('oregon'),
                    'PA' => $translate->_('pennsylvania'),            
                    'RI' => $translate->_('rhodeisland'),
                    'SC' => $translate->_('southcarolina'),            
                    'SD' => $translate->_('southdakota'),
                    'TN' => $translate->_('tennessee'),            
                    'TX' => $translate->_('texas'),
                    'UT' => $translate->_('utah'),            
                    'VT' => $translate->_('vermont'),
                    'VA' => $translate->_('virginia'),            
                    'WA' => $translate->_('washington'),
                    'WV' => $translate->_('westvirginia'),            
                    'WI' => $translate->_('wisconsin'),
                    'WY' => $translate->_('wyoming'),            
                    'IA' => $translate->_('iowa'),
                    'NM' => $translate->_('newmexico')
                  );
         return $state;
    }

    public static function getState($key){
        $state = StateConstant::getStateList();
        if(isset($state[$key])){
            return $state[$key];
        }
        return $key;
    }
    
}